﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Domaine.Entity
{
    public class AspApplication
    {
        #region Members

        string _ApplicationName;

        #endregion

        #region Ctor

        public AspApplication() { ApplicationID = Guid.NewGuid(); }

        #endregion


        #region Properties

        [Key]
        public Guid ApplicationID { get; set; }

        [Required]
        [MaxLength(256)]
        public string LoweredApplicationName { get; set; }

        [Required]
        [MaxLength(256)]
        public string ApplicationName
        {
            get { return _ApplicationName; }
            set { _ApplicationName = value; LoweredApplicationName = value.ToLower(); }
        }

        #endregion
    }
}
